home *** CD-ROM | disk | FTP | other *** search
/ Games of Daze / Infomagic - Games of Daze (Summer 1995) (Disc 1 of 2).iso / x2ftp / msdos / watcom / watkey2 / key.h < prev    next >
C/C++ Source or Header  |  1995-04-16  |  4KB  |  130 lines

  1. void installKeyboardHandler(void);
  2. void removeKeyboardHandler(void);
  3. char kbHit(void);
  4. void waitKey(void);
  5. char checkKey(short keyNum);
  6. void singleHitProcess(void);
  7. void toggleSingleHitKey(short keyNum);
  8. void clearKeys(void);
  9. char *getCodeBuffer(void);
  10. void setAliasKey(short alias,char keyNum);
  11.  
  12. #define KEY_BREAK          0xFF
  13.  
  14. #define KEY_ESC            0x01
  15. #define KEY_F1             0x3b
  16. #define KEY_F2             0x3c
  17. #define KEY_F3             0x3d
  18. #define KEY_F4             0x3e
  19. #define KEY_F5             0x3f
  20. #define KEY_F6             0x40
  21. #define KEY_F7             0x41
  22. #define KEY_F8             0x42
  23. #define KEY_F9             0x43
  24. #define KEY_F10            0x44
  25. #define KEY_F11            0x57
  26. #define KEY_F12            0x58
  27. #define KEY_SYSRQ          0xb7
  28. #define KEY_SCROLLLOCK     0x46 
  29.  
  30. #define KEY_TICK           0x29 
  31. #define KEY_1              0x02
  32. #define KEY_2              0x03
  33. #define KEY_3              0x04
  34. #define KEY_4              0x05
  35. #define KEY_5              0x06
  36. #define KEY_6              0x07
  37. #define KEY_7              0x08
  38. #define KEY_8              0x09
  39. #define KEY_9              0x0a
  40. #define KEY_0              0x0b
  41. #define KEY_MINUS          0x0c
  42. #define KEY_EQUAL          0x0d
  43. #define KEY_BACKSPACE      0x0e
  44. #define KEY_INSERT         0xd2
  45. #define KEY_HOME           0xc7
  46. #define KEY_PAGEUP         0xc9
  47. #define KEY_NUMLOCK        0x45 
  48. #define KEY_PADSLASH       0xb5
  49. #define KEY_PADSTAR        0x37
  50. #define KEY_PADMINUS       0x4a
  51.  
  52. #define KEY_TAB            0x0f
  53. #define KEY_Q              0x10
  54. #define KEY_W              0x11
  55. #define KEY_E              0x12
  56. #define KEY_R              0x13
  57. #define KEY_T              0x14
  58. #define KEY_Y              0x15
  59. #define KEY_U              0x16
  60. #define KEY_I              0x17
  61. #define KEY_O              0x18
  62. #define KEY_P              0x19
  63. #define KEY_LEFTBRACKET    0x1a
  64. #define KEY_RIGHTBRACKET   0x1b
  65. #define KEY_BACKSLASH      0x2b
  66. #define KEY_DELETE         0xd3
  67. #define KEY_END            0xcf
  68. #define KEY_PAGEDOWN       0xd1
  69. #define KEY_PAD7           0x47
  70. #define KEY_PAD8           0x48
  71. #define KEY_PAD9           0x49
  72. #define KEY_PADPLUS        0x4e
  73.  
  74. #define KEY_CAPSLOCK       0x3a
  75. #define KEY_A              0x1e
  76. #define KEY_S              0x1f
  77. #define KEY_D              0x20
  78. #define KEY_F              0x21
  79. #define KEY_G              0x22
  80. #define KEY_H              0x23
  81. #define KEY_J              0x24
  82. #define KEY_K              0x25
  83. #define KEY_L              0x26
  84. #define KEY_SEMICOLON      0x27
  85. #define KEY_APOSTROPHE     0x28
  86. #define KEY_ENTER          0x1c
  87. #define KEY_PAD4           0x4b
  88. #define KEY_PAD5           0x4c
  89. #define KEY_PAD6           0x4d
  90.  
  91. #define KEY_LEFTSHIFT      0x2a
  92. #define KEY_Z              0x2c
  93. #define KEY_X              0x2d
  94. #define KEY_C              0x2e
  95. #define KEY_V              0x2f
  96. #define KEY_B              0x30
  97. #define KEY_N              0x31
  98. #define KEY_M              0x32
  99. #define KEY_COMMA          0x33
  100. #define KEY_PERIOD         0x34
  101. #define KEY_SLASH          0x35
  102. #define KEY_RIGHTSHIFT     0x36
  103. #define KEY_UPARROW        0xc8
  104. #define KEY_PAD1           0x4f
  105. #define KEY_PAD2           0x50
  106. #define KEY_PAD3           0x51
  107. #define KEY_PADENTER       0x9c
  108.  
  109. #define KEY_LEFTCTRL       0x1d
  110. #define KEY_LEFTWINDOW     0xdb
  111. #define KEY_LEFTALT        0x38 
  112. #define KEY_SPACE          0x39
  113. #define KEY_RIGHTALT       0xb8 
  114. #define KEY_RIGHTWINDOW    0xdc
  115. #define KEY_KEYBOARDMOUSE  0xdd
  116. #define KEY_RIGHTCTRL      0x9d
  117. #define KEY_LEFTARROW      0xcb
  118. #define KEY_DOWNARROW      0xd0
  119. #define KEY_RIGHTARROW     0xcd
  120. #define KEY_PAD0           0x52
  121. #define KEY_PADPERIOD      0x53
  122.  
  123. //alias's must be after 255 and before 512
  124. #define ALIAS_GOFORWARD    0x101
  125. #define ALIAS_GOBACKWARD   0x102
  126. #define ALIAS_ROTATELEFT   0x103
  127. #define ALIAS_ROTATERIGHT  0x104
  128. #define ALIAS_MAP          0x105
  129.  
  130.